scoreboard players add @s rmr.entity.timer 1
execute if score @s rmr.entity.timer matches 15.. run return run kill @s

# fly
execute store result entity @s Motion[0] double 0.01 run scoreboard players get @s rmr.entity.flying_axe.x_speed
execute store result entity @s Motion[1] double 0.01 run scoreboard players get @s rmr.entity.flying_axe.y_speed
execute store result entity @s Motion[2] double 0.01 run scoreboard players get @s rmr.entity.flying_axe.z_speed

# execute if score @s rmr.entity.cycle_tick matches 0 run function rmr:entity/flying_axe/fly with storage minecraft:rmr arguments
# end

# damage
execute at @s run function rmr:entity/flying_axe/select_target
execute store result storage minecraft:rmr arguments.damage double 0.01 run scoreboard players get @s rmr.entity.flying_axe.damage
function rmr:entity/flying_axe/deal_damage with storage minecraft:rmr arguments
# end
